home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 22 / Cream of the Crop 22.iso / os2 / edm0407s.zip / STAT3SRC.ZIP / STATLINE.HPP < prev    next >
C/C++ Source or Header  |  1996-07-25  |  3KB  |  53 lines

  1. #ifndef _STATLINE_HPP_
  2. #define _STATLINE_HPP_
  3.  
  4. #include <iframe.hpp>           //Include IFrameWindow Class Header
  5. #include <imenubar.hpp>
  6. #include <istattxt.hpp>
  7. #include <ipainhdr.hpp>
  8. #include <ikeyhdr.hpp>
  9. #include <ithread.hpp>
  10. #include <icmdhdr.hpp>
  11. #include <ifont.hpp>
  12. #include <istring.hpp>
  13.  
  14. #include "editfile.hpp"
  15. #include "procssta.hpp"
  16. #include "usermsgh.hpp"
  17.  
  18. class AStatusLineSample : public IFrameWindow,
  19.                           public IKeyboardHandler,
  20.                           public ICommandHandler,
  21.                           public AUserMessageHandler
  22.  
  23. {
  24.   public:                               
  25.     AStatusLineSample (unsigned long windowId);       // Constructor
  26.     ~AStatusLineSample (void);                        // Destructor for this class
  27.  
  28.   protected:
  29.     void setupVariables (void);                       // set up the variables
  30.     void setupStatusLine (void);                      // set up the progress-indicating status line
  31.     Boolean virtualKeyPress (IKeyboardEvent& event);  // handle virtual key press
  32.     Boolean command(ICommandEvent &evt);              // command handling
  33.     Boolean startOpenFile (void);                     // prepare to open a file
  34.     void openFile (void);                             // read the file inside of a separate thread
  35.     Boolean openFileReady (IEvent& evt);              // called when sub-thread has finished
  36.     Boolean startSaveFile (void);                     // prepare to save a file
  37.     void saveFile (void);                             // write the file inside of a separate thread
  38.     Boolean saveFileReady (IEvent& evt);              // called when sub-thread has finished
  39.     Boolean loadString (unsigned long ulStringId);    // load a string from the resource library
  40.  
  41.   private:
  42.     IMenuBar * m_pMenuBar;                            // pointer to the menu bar
  43.     IStaticText * m_pText;                            // text inside of the client area
  44.     IThread * m_pFileThread;                          // the thread to read/write a file
  45.     IString m_sFilename,                              // keeps the filename
  46.             m_String;                                 // working string
  47.     AEditFile * m_pEditFile;                          // the file
  48.     AProcessStatus * m_pStatusLine;                   // the progress-indicating status line
  49.     PROCESS_START_PARAMS m_startParams;               // parameters passed to the status line
  50. };
  51.  
  52. #endif //_STATLINE_HPP_
  53.